<template>
    <div>待配提示</div>
    <el-table :data="list" style="width: 100%">
        <el-table-column prop="pendingPromptsId" label="序号" />
        <el-table-column prop="auricle" label="种母耳号" />
        <el-table-column prop="emptyDay" label="空怀天数" />
        <el-table-column prop="buildingName" label="栋舍" />
        <el-table-column prop="columnsName" label="栏位" />
        <el-table-column prop="breedsStatus" label="繁殖状态">
            <template v-slot="scope">
                <span v-if="scope.row.pregnancyName == 1">已繁殖</span>
                <span v-else>未繁殖</span>
            </template>
        </el-table-column>
        <el-table-column prop="breedsDate" label="事件日期">
            <template v-slot="scope">
                {{ scope.row.breedsDate.substring(0, 10) }}
            </template>
        </el-table-column>
        <el-table-column prop="sheepId" label="提示类型">
            <template v-slot="scope">
                <span v-if="scope.row.pregnancyName == 1">刚怀上</span>
                <span v-else>即将临产</span>
            </template>
        </el-table-column>
    </el-table>
</template>
<script setup lang="ts">
import { reactive, ref, onMounted } from 'vue'
import axios from 'axios';
const list = ref([])
const getlist = () => {
    axios.post("http://localhost:5012/api/Prompt/pendingPromptsList", {}).then(res => {
        list.value = res.data.data
    })
}
onMounted(() => {
    getlist()
})
</script>